<%--
  Created by cofey on 16/11/20.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title><sitemesh:write property='title'/> - 无线南山统一管理平台</title>
    <link href="${assets}/css/commons.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="${assets}/js/jquery.min.js"></script>
    <script type="text/javascript" src="${assets}/js/jquery.form.js"></script>
    <script type="text/javascript" src="${assets}/js/commons.js"></script>
    <script type="text/javascript" src="${assets}/js/jquery.tab.js"></script>
    <script type="text/javascript" src="${assets}/plugin/page.js"></script>
    <script type="text/javascript" src="${assets}/plugin/date/WdatePicker.js"></script>
    <script type="text/javascript" src="${assets}/plugin/layer/layer.js"></script>
    <sitemesh:write property='head'/>
</head>
<body>
<div id="dcWrap">
    <div id="dcHead">
        <div id="head">
            <div class="logo"><a href="#"><img width="180" height="40" src="${assets}/img/logo.png" alt="logo"></a>
            </div>
            <div class="nav">
                <ul>
                    <li><a href="${ctx}/hotspot/statistics">热点统计</a></li>
                    <li><a href="${ctx}/ap/statistics">AP设备统计</a></li>
                    <li><a href="${ctx}/ma/statistics">短信认证统计</a></li>
                    <li class="noRight"><a href="${ctx}/lr/statistics">本地化资源统计</a></li>
                </ul>
                <ul class="navRight">
                    <li class="noLeft"><a href="javascript:updateUserPwd();">您好，${currUser.userName}</a></li>
                    <li class="noRight"><a href="${ctx}/logout">退出</a></li>
                </ul>
            </div>
        </div>
    </div>
    <!-- dcHead 结束 -->
    <div id="dcLeft">
        <div id="menu">
            <ul class="top">
                <li><a href="${ctx}/index"><i class="home"></i><em>平台首页</em></a></li>
            </ul>
            <ul>
                <%--class="cur"--%>
                <li><a href="${ctx}/hotspot/"><i class="page"></i><em>热点管理</em></a></li>
                <li><a href="${ctx}/ap/"><i class="nav"></i><em>设备运行情况</em></a></li>
                <li><a href="${ctx}/hotspot/statistics/2"><i class="productCat"></i><em>热点统计</em></a></li>
                <li><a href="${ctx}/ap/statistics/2"><i class="product"></i><em>AP统计</em></a></li>
                <li><a href="${ctx}/ma/statistics"><i class="mobile"></i><em>短信认证统计</em></a></li>
                <!--li><a href="${ctx}/lr/statistics"><i class="show"></i><em>本地化资源统计</em></a></li-->
            </ul>
            <ul>
                <li><a href="${ctx}/ua/"><i class="manager"></i><em>用户认证</em></a></li>
                <li><a href="${ctx}/ma/"><i class="mobile"></i><em>短信认证</em></a></li>
            </ul>
            <ul>
                <li><a href="${ctx}/build"><i class="theme"></i><em>安全审计</em></a></li>
                <li><a href="${ctx}/build"><i class="articleCat"></i><em>数据分析与挖掘</em></a></li>
                <li><a href="${ctx}/portal/am"><i class="system"></i><em>Portal管理</em></a></li>
                <li><a href="${ctx}/ent/"><i class="managerLog"></i><em>政企信息管理</em></a></li>
                <li><a href="${ctx}/lr/"><i class="show"></i><em>本地化资源管理</em></a></li>
            </ul>
            <ul class="bot">
                <li><a href="${ctx}/other/structure"><i class="link"></i><em>平台构架及组成部分</em></a></li>
                <li><a href="${ctx}/other/hardware"><i class="plugin"></i><em>硬件选型和配置</em></a></li>
                <li><a href="${ctx}/other/estimate"><i class="backup"></i><em>年度评估指标体系</em></a></li>
                <li><a href="${ctx}/other/complaint"><i class="guestbook"></i><em>投诉处理</em></a></li>
            </ul>
        </div>
    </div>
    <div id="dcMain">
        <sitemesh:write property='body'/>
    </div>
    <div class="clear"></div>
    <div id="dcFooter">
        <div id="footer">
            <div class="line"></div>
            <ul>
                版权所有 © 2008-2017 深圳市盛思源实业发展有限公司，并保留所有权利。
            </ul>
        </div>
    </div><!-- dcFooter 结束 -->
    <div class="clear"></div>

    <div id="updateUserPwd" style="display: none;">
        <table width="100%">
            <tr>
                <td width="20%">旧密码</td>
                <td width="80%"><input type="password" class="inpMain" name="oldPassword"/></td>
            </tr>
            <tr>
                <td>新密码</td>
                <td><input type="password" class="inpMain" name="newPassword"/></td>
            </tr>
            <tr>
                <td>确认密码</td>
                <td><input type="password" class="inpMain" name="confirmPassword"/></td>
            </tr>
        </table>
    </div>
    <script type="text/javascript">
        function updateUserPwd() {
            layer.open({
                type: 1,
                title: '修改用户密码',
                area: ['300px'],
                btn: ['关闭', '确认'],
                btn1: function (index) {
                    layer.close(index);
                },
                btn2: function (index) {
                    var oldPassword = $('#updateUserPwd').find('input[name=oldPassword]').val();
                    var newPassword = $('#updateUserPwd').find('input[name=newPassword]').val();
                    var confirmPassword = $('#updateUserPwd').find('input[name=confirmPassword]').val();
                    $.post("${ctx}/updateUserPwd", {
                        oldPassword: oldPassword,
                        newPassword: newPassword,
                        confirmPassword: confirmPassword
                    }, function (res) {
                        if (res.errorCode == 0) {
                            layer.msg(res.result);
                            layer.close(index);
                            $('#updateUserPwd').find('input[name=oldPassword]').val();
                            $('#updateUserPwd').find('input[name=newPassword]').val();
                            $('#updateUserPwd').find('input[name=confirmPassword]').val();
                        } else {
                            layer.msg(res.errorMessage);
                            return false;
                        }
                    });
                    return false;
                },
                content: $('#updateUserPwd')
            });
            $('.layui-layer-btn a:contains("确认")').addClass('btn');
            $('.layui-layer-btn a:contains("关闭")').addClass('btnGray');
        }
    </script>
</div>
</body>
</html>